import {request} from 'umi'
import {IExam,createExam} from '../interface/examList'


//获取考试所有类型
export const get_listexam = ()=>{
    return request('/exam/exam',{method:'GET'})
}

//获取所有的考试类型
export const get_examType=()=>{
    return request('/exam/examType',{method:'GET'})
}
//获取所有课程
export const get_examsubject=()=>{
    return request('/exam/subject',{method:'GET'})
}

//按条件获取试题
export const get_questions=()=>{
    return request('/exam/questions/condition',{method:'GET'})
}

//创建试卷列表
export const add_listexam=(data:createExam)=>{
    return request('/exam/exam',{method:"POST",data})
}